<?php
/*! \brief
 * This is WFProxyFactory class
 * This is the Simple Factory Class that create relative Proxy Class
 * \author William Su
 */
class WFProxyFactory
{
	private static $instance;
	/**
	 * @var WF
	 */
	private $objFramework;
	public function __construct($objFramework){
		$this->objFramework = $objFramework;
	}
    public static function getDirnameFile(){
		if(!isset(self::$instance[__FUNCTION__])){
		    self::$instance[__FUNCTION__] = dirname(__FILE__);
		}
		return self::$instance[__FUNCTION__];
	}
	/**
	 * @return WFHttpTalk
	 */
	public function getHttpTalk(){
		if(!isset(self::$instance[__FUNCTION__])){
			require_once self::getDirnameFile().'/HttpTalk.php';
		}
		self::$instance[__FUNCTION__] = new WFHttpTalk();
		return self::$instance[__FUNCTION__];
	}
}
